Skip to content

feat(server): Add server config for headers and keep alive timeouts #9309

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

marianore-muttdata
Copy link
Contributor

@marianore-muttdata marianore-muttdata commented Mar 6, 2025

Check List

  • Tests have been run in packages where changes made if available
  • Linter has been run for changed code
  • Docs have been added / updated if required
  • Tests for the changes have been added if not covered yet

Description of Changes Made

This is a change that we've been using in our application to sync the timeouts with the LoadBalancer correctly.

Added two new environment variables to configure HTTP server options:

  • CUBEJS_SERVER_HEADERS_TIMEOUT
  • CUBEJS_SERVER_KEEP_ALIVE_TIMEOUT

Each default to the default values in the Server class found in the HTTP Node module.

@marianore-muttdata marianore-muttdata requested a review from a team as a code owner March 6, 2025 16:46
@github-actions github-actions bot added the pr:community Contribution from Cube.js community members. label Mar 6, 2025
@marianore-muttdata marianore-muttdata force-pushed the feat/cube/add-node-keep-alive-headers-timeout-configs branch from 2c3f332 to 51681fd Compare March 6, 2025 17:03
@marianore-muttdata
Copy link
Contributor Author

Hi @KSDaemon! Do you think this feature could be added anytime soon? Do you see any utility?
We're actually using it productively ;)

@KSDaemon
Copy link
Member

Hey @marianore-muttdata looks good. Could you please rebase it on top of the latest master branch? GitHub shows that there are some conflicts. Thnx!

@marianore-muttdata marianore-muttdata requested review from a team as code owners June 17, 2025 14:18
@marianore-muttdata marianore-muttdata force-pushed the feat/cube/add-node-keep-alive-headers-timeout-configs branch from f884557 to 267ce43 Compare June 17, 2025 14:19
@KSDaemon
Copy link
Member

Hey @marianore-muttdata! Actually... The tests are failing because of:

    Error: Invalid cube-server-core options: "serverHeadersTimeout" is not 
      allowed. "serverKeepAliveTimeout" is not allowed

We forgot to update the options scheme here

@marianore-muttdata
Copy link
Contributor Author

Hey @marianore-muttdata! Actually... The tests are failing because of:

    Error: Invalid cube-server-core options: "serverHeadersTimeout" is not 
      allowed. "serverKeepAliveTimeout" is not allowed

We forgot to update the options scheme here

Got it! Let me know if there's anything else that you'd write differently.

@KSDaemon
Copy link
Member

I think now everything is fine! :) Let's merge!

@KSDaemon KSDaemon merged commit 8fd2c42 into cube-js:master Jun 18, 2025
59 checks passed
@marianore-muttdata marianore-muttdata deleted the feat/cube/add-node-keep-alive-headers-timeout-configs branch June 19, 2025 23:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr:community Contribution from Cube.js community members.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants